Field of the Invention
The invention relates to data storage, and more particularly to flash memories.
Description of the Related Art
A flash memory is a non-volatile memory. When a power of the flash memory is cut off, the data stored in the flash memory does not disappear. The flash memory is therefore widely used in applications with limited power such as portable electronic devices. A flash memory comprises a plurality of memory cells, and each memory cell stores a voltage with a level selected from 2N predetermined levels. For example, a memory cell of a single level cell (SLC) flash memory stores a voltage with a level selected from two predetermined levels. Similarly, a memory cell of a multiple level cell (MLC) flash memory stores a voltage with a level selected from four predetermined levels, and a memory cell of a triple level cell (TLC) flash memory stores a voltage with a level selected from eight predetermined levels.
When a host wants to read data from a target cell of the flash memory, the controller first determines a set of read voltages, and determines in which range of the read voltages a voltage level stored in the target cell falls, thereby determining the bit value stored in the target cell. For example, when the flash memory is an SLC flash memory, the read voltage set has a single voltage threshold. When a voltage level of a target cell is higher than the voltage threshold, the controller determines the data bit value stored in the target cell to be a bit 0. When the voltage level of the target cell is lower than the voltage threshold, the controller determines the data bit value stored in the target cell to be a bit 1. In addition, when the flash memory is an MLC flash memory, the read voltage set has three voltage thresholds, and the controller can therefore determine the data bit value stored in the target cell to be 11, 01, 00, or 10 according to a comparison result between the voltage level of the target cell and the three voltage thresholds of the read voltage set. Similarly, when the flash memory is a TLC flash memory, the read voltage set has seven voltage thresholds, and the controller can therefore determine the data bit value stored in the target cell to be 111, 011, 001, 101, 100, 000, 010, or 110 according to a comparison result between the voltage level of the target cell and the seven voltage thresholds of the read voltage set. FIG. 1 shows a schematic diagram of a read voltage set corresponding to a TLC memory. The read voltage set has different thresholds in correspondence to a number of data bits stored in a target cell of the TLC memory.
A read voltage therefore determines a data value read out from a target cell of a flash memory. In other words, data bits stored in a target cell of a flash memory are determined to be different values according to different read voltages. When a controller reads a flash memory to obtain read-out data with error bits, the controller therefore should try to read the flash memory according to different read voltages. Thus, the invention provides a data read method for a flash memory. According to the data read method, when read-out data has error bits, the read voltage is appropriately adjusted to read the flash memory again to obtain correct read-out data.